import request from '@/utils/request'

// 查询
export function getAllList(query) {
  return request({
    url:query.islogin?'/courseManage/getOnlinePage':`/courseManage/getPage`,
    method: 'get',
    params:query
  })
}

// 随机题
export function getTestById(query) {
  return request({
    url:`/questionData/getTestById`,
    method: 'get',
    params:query
  })
}

// 提交试卷
export function submitText(query) {
  return request({
    url:`/questionData/getScore`,
    method: 'post',
    data:query
  })
}


// 获取历史考试信息
export function getTestList(query) {
  return request({
    url:`/courseManage/getTestListByCourseId`,
    method: 'get',
    params:query
  })
}